package com.dein.broadcast.dao;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.dein.broadcast.model.Broadcast;
import com.dein.music.model.Music;

public interface BroadcastDao {
	public String broadcastExist(String broadcastName);

	public void addBroadcast(Broadcast broadcast);

	public void addBroadcastMusicList(
			@Param(value = "broadcastId") int broadcastId,
			@Param(value = "musicIds") long[] musicIds);

	public List<Broadcast> getBroadcastList();

	public List<Music> getBroadcastMusicList(int broadcastId);

	public void updateBroadcast(@Param(value = "broadcastId") int broadcastId,
			@Param(value = "broadcastName") String broadcastName);

	public void deleteBroadcastMusic(
			@Param(value = "broadcastId") int broadcastId,
			@Param(value = "musicId") long musicId);

	public void addBroadcastMusic(
			@Param(value = "broadcastId") int broadcastId,
			@Param(value = "musicId") long musicId);

	public void deleteBroadcast(int broadcastId);

	public List<Music> playPublicBroadcast(
			@Param(value = "broadcastId") int broadcastId,
			@Param(value = "begin") int begin,
			@Param(value = "howMany") int howMany);

	public int numberOfSongsOnPublicBroadcast(int broadcastId);

	public List<Music> playRedHeartBroadcast(
			@Param(value = "userId") long userId,
			@Param(value = "begin") int begin,
			@Param(value = "howMany") int howMany);

	public int numberOfSongsOnRedHeartBroadcast(long userId);

	public List<Music> playPrivateBroadcast(
			@Param(value = "userId") long userId,
			@Param(value = "howMany") int howMany);

}
